/*
 *      Copyright (c) 2018-2028, Chill Zhuang All rights reserved.
 *
 *  Redistribution and use in source and binary forms, with or without
 *  modification, are permitted provided that the following conditions are met:
 *
 *  Redistributions of source code must retain the above copyright notice,
 *  this list of conditions and the following disclaimer.
 *  Redistributions in binary form must reproduce the above copyright
 *  notice, this list of conditions and the following disclaimer in the
 *  documentation and/or other materials provided with the distribution.
 *  Neither the name of the dreamlu.net developer nor the names of its
 *  contributors may be used to endorse or promote products derived from
 *  this software without specific prior written permission.
 *  Author: Chill 庄骞 (smallchill@163.com)
 */
package org.springblade.mes.system.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableName;
import com.fasterxml.jackson.databind.annotation.JsonSerialize;
import com.fasterxml.jackson.databind.ser.std.NullSerializer;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;
import org.springblade.core.tenant.mp.TenantEntity;

import java.util.Date;
import java.util.List;

/**
 * 客户档案表实体类
 *
 * @author shiwei
 * @since 2021-02-23
 */
@Data
@TableName("sale_customer")
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "Customer对象", description = "客户档案表")
public class Customer extends TenantEntity {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty(value = "工程师的id", required = true)
    @JsonSerialize(nullsUsing = NullSerializer.class)
    private Long engineerId;


    @ApiModelProperty(value = "工程师姓名", required = true)
    private String engineerName;

    @ApiModelProperty(value = "客户编号")
    private String customerNumber;

    @ApiModelProperty(value = "客户姓名", required = true)
    private String customerName;

    @ApiModelProperty(value = "客户状态", required = true)
    private String customerType;

    @ApiModelProperty(value = "类型") //A类   B类  C类  D类
    private String type;

    @ApiModelProperty(value = "供货类型")
    private String supplyType;

    @ApiModelProperty(value = "主机厂")
    private String enginePlants;

    @ApiModelProperty(value = "客户地址", required = true)
    private String customerAddress;

    @ApiModelProperty(value = "客户信用度")
    private String customerCredit;

    @ApiModelProperty(value = "公司性质", required = true)
    private String companyNature;

    @ApiModelProperty(value = "公司规模", required = true)
    private String companyScale;

    @ApiModelProperty(value = "客户来源")
    private String customerSource;

    @ApiModelProperty(value = "所属行业", required = true)
    private String industryInvolved;

    @ApiModelProperty(value = "所属地区", required = true)
    private String industryArea;

    @ApiModelProperty(value = "注册金额(万元)")
    private String registeAmount;

    @ApiModelProperty(value = "客户经营范围", required = true)
    private String manageScope;

    @ApiModelProperty(value = "备注")
    private String remark;

    @ApiModelProperty(value = "购货单位全称")
    private String purchaseName;

    @ApiModelProperty(value = "纳税人登记号")
    private String registerNumber;

    @ApiModelProperty(value = "账号")
    private String accountNumber;

    @ApiModelProperty(value = "开户行")
    private String openBank;

    @ApiModelProperty(value = "地址")
    private String address;

    @ApiModelProperty(value = "电话号码")
    private String phone;

    @ApiModelProperty(value = "产品质量")
    private String productQuality;

    @ApiModelProperty(value = "包装要求")
    private String packagRequirement;

    @ApiModelProperty(value = "特殊要求")
    private String specialRequirement;

    @ApiModelProperty(value = "付款方式")
    private String payMethod;

    @ApiModelProperty(value = "结算类别")
    private String settlementCategory;

    @ApiModelProperty(value = "特殊折扣")
    private String channelDiscount;

    @ApiModelProperty(value = "运输交付")
    private String transportDelivery;

    @ApiModelProperty(value = "环保")
    private String environmental;

    @ApiModelProperty(value = "退/换货")
    private String changeGoods;

    @ApiModelProperty(value = "技术支持")
    private String technicalSupport;

    @ApiModelProperty(value = "其他要求")
    private String elseRequire;

    @ApiModelProperty(value = "工程师姓名")
    @TableField(exist = false)
    private String engineerIdstr;

    @ApiModelProperty(value = "创建人姓名")
    @TableField(exist = false)
    private String createUserstr;
    private String createUserName;
    //流程开始时间
    private Date applyTime;
    //流程定义id
    private String processDefinitionId;
    //流程实例id
    private String processInstanceId;
    @ApiModelProperty(value = "附件的ids")
    @TableField(exist = false)
    private String ids;

    @ApiModelProperty(value = "货币类型")
    private String currencyType;

    @ApiModelProperty(value = "联系人")
    @TableField(exist = false)
    private List<CustomerLinkman> customerLinkmanList;

    @ApiModelProperty(value = "客户")
    @TableField(exist = false)
    private List<String> stringList;

    @ApiModelProperty(value = "联系人姓名")
    @TableField(exist = false)
    private String linkmanName;

    @ApiModelProperty(value = "商务标识 0否，1是")
    private String businessFlag;

    @ApiModelProperty(value = "商务主体id")
    private String businessSubjectId;

    @ApiModelProperty(value = "商务主体名称")
    private String businessSubjectIdName;

    @ApiModelProperty(value = "收货地址")
    @TableField(exist = false)
    private List<CustomerAddress> customerAddressList;

    @ApiModelProperty(value = "excel状态str")
    @TableField(exist = false)
    private String statusStr;

    @ApiModelProperty(value = "excel客户状态str")
    @TableField(exist = false)
    private String customerTypeStr;

    @ApiModelProperty(value = "excel公司性质str")
    @TableField(exist = false)
    private String companyNatureStr;

    @ApiModelProperty(value = "excel公司规模str")
    @TableField(exist = false)
    private String companyScaleStr;

    @ApiModelProperty(value = "excel所属行业str")
    @TableField(exist = false)
    private String industryInvolvedStr;

    @ApiModelProperty(value = "excel所属地区str")
    @TableField(exist = false)
    private String industryAreaStr;

    @ApiModelProperty(value = "excel客户信用度str")
    @TableField(exist = false)
    private String customerCreditStr;

    @ApiModelProperty(value = "excel创建时间str")
    @TableField(exist = false)
    private String createTimeStr;

    @ApiModelProperty(value = "国别")
    private String country;
    @ApiModelProperty(value = "币种")
    private String currency;

    @ApiModelProperty(value = "账期(天)")
    @JsonSerialize(nullsUsing = NullSerializer.class)
    private Integer accountPeriod;


    @ApiModelProperty(value = "其他系统编码")
    private String otherSysCode;
    @ApiModelProperty(value = "其他系统编码2")
    private String otherSysCode2;

    @ApiModelProperty(value = "客户等级")
    private String customerLevel;
    @ApiModelProperty(value = "网络地址")
    private String networkAddress;

    @ApiModelProperty(value = "发票种类")
    private String invoiceType;

    @ApiModelProperty(value = "客户分级")
    @JsonSerialize(nullsUsing = NullSerializer.class)
    private Integer customerGrade;

}
